import { knowledgeModelState, useSelector } from "umi";
import right from "./right.less"
export default function Suspend() {
    const { tuilist } = useSelector((state: { knowledge: knowledgeModelState }) => {
        return state.knowledge
    });
    const { categorylist } = useSelector((state: { knowledge: knowledgeModelState }) => {
        return state.knowledge
    });
    return (
        <div className={right.right}>
            <div className={right.tui}>
                <h2>推荐阅读</h2>
                <ul>
                    {tuilist.map((item: any) => {
                        return <li key={item.id}>{item.title}</li>
                    })}
                </ul>
            </div>
            <div className={right.wen}>
                <h2>文章分类</h2>
                <ul>
                    {categorylist.map((item: any) => {
                        return <li key={item.id}>{item.label} <span>共计{item.articleCount}篇文章</span></li>
                    })}
                </ul>
            </div>
        </div>
    );
}





